import { isString } from '@vue/shared'
import type { PropType } from "vue";

import type { MentionOption } from './types'
const definePropType = <T>(val: any): PropType<T> => val;

export const mentionDropdownProps ={
  options: {
    type: definePropType<MentionOption[]>(Array),
    default: () => [],
  },
  loading: Boolean,
  disabled: Boolean,
  contentId: String,
  ariaLabel: String,
}

export const mentionDropdownEmits = {
  select: (option: MentionOption) => isString(option.value),
}
